package com.topit.show.wxapi.vo;

public class UploadMedia {
    //三天的时间戳
    private static final Long THREE_DAY = 3 * 24 * 60 * 60 * 1000L;

    private String type;

    private String media_id;

    private Long created_at;

    public String getType() {
        return type;
    }

    public void setType(String type) {
        this.type = type;
    }

    public String getMedia_id() {
        return media_id;
    }

    public void setMedia_id(String media_id) {
        this.media_id = media_id;
    }

    public Long getCreated_at() {
        return created_at;
    }

    public void setCreated_at(Long created_at) {
        this.created_at = created_at;
    }

    public boolean isExpires() {
        return System.currentTimeMillis() - created_at >= THREE_DAY;
    }

    @Override
    public String toString() {
        return "UploadMedia [media_id=" + media_id + ", created_at=" + created_at + ", isExpires=" + isExpires() + "]";
    }
}
